<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>充值方案</title>
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<script src="__INDEX__/js/mui.min.js"></script>
	    <link href="__INDEX__/css/mui.min.css" rel="stylesheet"/>
		<link rel="stylesheet" href="__INDEX__/css/style.css" />
		<link rel="stylesheet" href="__INDEX__/css/hykcz.css" />
	</head>
	<body class="czfa_content">
		<header class="mui-bar mui-bar-nav" >
		    <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left" ></a>
		    <h1 class="mui-title" >确认付款</h1>
		</header>
		<div class="mui-content czfa_content">
			<div class="qrfkb_czk clearfix">
				<div class="top">
					<div class="top_left"><img  class="top_img" src="{$user.logo}"/></div>
					<div class="top_right">
						<p>鸿运酒店</p>
						<p>{$user.name}</p>
					</div>
				</div>
				
				<div class="idnum">ID:{$user.id}</div>
				<div class="mnum">{$user.balance}</div>
			</div>
			<div class="bt"><img src="__INDEX__/img/czfabt.jpg"></div>
			<ul class="hycz_list">
				{foreach name="list" item="l" }
				<li data-val="{$l.id}">
					<div class="left">¥<em>{$l.money}</em></div>
					<div class="right">
						<p>实际获得{$l.balance}元</p>
					</div>
				</li>
				{/foreach}
				
			</ul>
			<a href="#" class="hyk_btn hycz_btn">立即充值</a>
			<div class="hycz_tip">充值说明</div>
			
		</div>
			<form method="post" id="my_form">
				<input type="hidden" name="cz_id" id="cz_id" >
			</form>
	</body>
</html>
{include file="public/footer" /}
<script>
	$(".hycz_list li").click(function(){
		$(".active").removeClass("active");
		$(this).addClass("active");
		$("#cz_id").val($(this).data('val'));
	})
	$(".hyk_btn").click(function(){
		var cz_money=$(".active").data("val");
		if(cz_money==undefined){
			layer.msg("请选择充值套餐");
			return;
		}else{
//			if($('#checkbox').is(':checked')==false) {
//				    layer.msg('请阅读购买协议');
//				    return;
//			}
			var btnArray = ['不同意', '同意'];
				mui.confirm('确认购买！', '确认购买', btnArray, function(e) {
					 if (e.index == 1) {
					 	$("#my_form").submit();
					 }
			})
		}
		
	})
</script>